<%-- 
    Document   : login
    Created on : 12 déc. 2012, 09:46:23
    Author     : CDI215
--%>

<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <link type="text/css" rel="stylesheet" href="<c:url value="/inc/style.css" />" />
        <title>Connexion</title>
    </head>
    <div id="header">
        <c:import url="/inc/header.jsp"/>
    </div>

    <div id="article">
        <form method="post" action="<c:url value="/Ctrl?section=connect"/>">
            <input type="hidden" name="action" value="connexion" />
            <fieldset>
                <legend>
                    Se connecter
                </legend>
                <label for="email">
                    Identifiant :
                </label>
                <input type="email" name="email" id="email" value="<c:out value="${client.login}"/>" size="30" maxlength="30"/>
                <span class="erreur">
                    <c:out value="${form.erreurs['email']}"/>
                </span>
                <br>
                <label for="mdp">
                    Mot de passe :
                </label>
                <input type="password" name="mdp" id="mdp" size="30" maxlength="30"/>

                <span class="erreur">
                    <c:out value="${form.erreurs['mdp']}"/>
                </span>
                <br>
                <label for="cc">
                    Rester connecté :
                </label>
                <input type="checkbox" name="cc" id="cc"/>
                <br>
                <c:choose>
                    <c:when test="${!tentative}">
                        <input class="sanslabel" type="submit" value="Valider"/>
                        <input type="reset" value="Annuler"/>
                    </c:when>
                    <c:otherwise>
                        <span class="erreur">
                        Trop de tentative de connexion ! Veuillez réessayer dans 5 minutes.<br/>
                        </span>
                        En cas d'oubli du mot de passe, <a href="mailto:ducdelafpa@afpa.biz">contactez-nous</a> !

                    </c:otherwise>
                </c:choose>
            </fieldset>
        </form>
        <form>
            <fieldset>
                <legend>S'inscrire</legend>
            </fieldset>
        </form>
    </div>
    <div id="nav">
        <c:import url="/inc/nav.jsp"/>
    </div>
    <div id="footer">
        <c:import url="/inc/footer.jsp"/>
    </div> 
</body>
</html>